import React, { Component } from 'react';
import {
  StyleSheet,
  View,
  Image,
  TouchableOpacity,
} from 'react-native';
import FontText from '../FontText';
import { scaleSize } from '../../../utils/screen';

class RewardAddItem extends Component {
  render() {
    const { onPress, text } = this.props;

    return (
      <TouchableOpacity
        activeOpacity={0.8}
        onPress={() => onPress && onPress()}
        style={styles.container}
      >
        <Image
          style={styles.iconImage}
          source={ require("../../../access/imgs/add_icon.png") }
        />
        <FontText
          style={styles.text}
          font={'medium'}
        >
          { text }
        </FontText>
      </TouchableOpacity>
    );
  }
}

/* StyleSheet =============================================================== */

const styles = StyleSheet.create({
  container: {
    height: scaleSize(500),
    width: scaleSize(350),
    justifyContent: 'center',
    alignItems: 'center',
  },
  iconImage: {
    width: scaleSize(50),
    height: scaleSize(50),
  },
  text: {
    fontSize: scaleSize(27),
    color: "#cfa972",
    marginTop: scaleSize(30),
  },
});

export default RewardAddItem;